/* 树形视图的基本样式 */
.custom-tree {
    list-style-type: none;
    padding: 0;
    margin: 0;
    font-size: 14px;
}

.custom-tree ul {
    list-style-type: none;
    margin: 0;
}

.custom-tree li {
    position: relative;
    padding: 0;
    margin: 0;
}

.custom-tree .tree-children:first-child {
    margin-top: 10px;
    margin-bottom: 15px;
    padding-left: 5px;
}

/* 树节点样式 */
.tree-node {
    display: flex;
    align-items: center;
    padding: 8px 10px;
    cursor: pointer;
    border-bottom: 1px solid #f4f4f4;
    transition: background-color 0.2s;
}

.tree-node:hover {
    background-color: #f5f5f5;
}

/* 展开/折叠图标 */
.toggle-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 5px;
}

/* 节点内容样式 */
.node-content {
    display: flex;
    align-items: center;
    flex-grow: 1;
}

.node-content a {
    display: flex;
    align-items: center;
    color: #333;
    text-decoration: none;
    flex-grow: 1;
}

.node-content a:hover {
    color: #3c8dbc;
}

.node-icon {
    margin-right: 5px;
    color: #3c8dbc;
    width: 16px;
    text-align: center;
}

/* 子树样式 - 只对非第一层级应用缩进 */
.tree-children .tree-children {
    padding-left: 15px;
}

/* 叶子节点样式 */
li:last-child>.tree-node {
    border-bottom: none;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .custom-tree {
        font-size: 12px;
    }

    .tree-node {
        padding: 6px 8px;
    }

    .tree-children .tree-children {
        padding-left: 10px;
    }
}

/* 优化小屏幕上的显示 */
@media (max-width: 480px) {
    .tree-children .tree-children {
        padding-left: 5px;
    }

    .node-content small {
        display: none;
    }
}